﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel;
using Test.Model;

namespace Test.ViewModel
{
    class StockViewModel : INotifyPropertyChanged
    {


        public StockViewModel()
        {

        }


        private int total;
        public int Total
        {
            set{total=value;NotifyPropertyChanged("Total");}
            get { return total; }
        }

        private int currentsize;
        public int Currentsize
        {
            get { return currentsize; }
            set { currentsize = value; NotifyPropertyChanged("Currentsize"); }
        }

        private int num;
        public int Num
        {
            get { return num; }
            set { num = value; NotifyPropertyChanged("Num"); }
        }

        private List<Stock> stocks;
        public List<Stock> Stocks
        {
            get { return stocks; }
            set { Stocks = value; NotifyPropertyChanged("Stocks"); }
        }






        #region INotifyPropertyChanged 成员

        public event PropertyChangedEventHandler PropertyChanged;
        public void NotifyPropertyChanged(string PropertyName)
        {
            if (PropertyChanged != null)
            {
                PropertyChanged(this, new PropertyChangedEventArgs(PropertyName));
            }
        }
        #endregion
    }

    public class Page
    {
        public string Name
        {
            set;
            get;
        }

        public int PageSize
        {
            set;
            get;
        }
    }

}
